import { areaList } from '@vant/area-data'

export const IdToAddress = (cityID) => {
  const provinceCode = cityID.slice(0, 2) + '0000'
  const cityCode = cityID.slice(0, 4) + '00'
  const districtCode = cityID

  const province = areaList.province_list[provinceCode]
  const city = areaList.city_list[cityCode]
  const district = areaList.county_list[districtCode]

  return { province, city, district }
}
